Add pcl version check for letting users know the version issue#39
Open
LimHyungTae wants to merge 1 commit intokoide3:masterfrom
Open
Add pcl version check for letting users know the version issue#39LimHyungTae wants to merge 1 commit intokoide3:masterfrom
LimHyungTae wants to merge 1 commit intokoide3:masterfrom
Conversation
Author
|
If your desktop has PCL 1.11.0, then please test it whether it works or not. |
valgur
reviewed
Apr 27, 2024
Comment on lines
58
to
+61
| find_package(PCL REQUIRED) | ||
| if(PCL_VERSION VERSION_LESS "1.11.0") | ||
| message(FATAL_ERROR "The found PCL version ${PCL_VERSION} is too low. Required is at least 1.11.0") | ||
| endif() |
Contributor
There was a problem hiding this comment.
Can be simplified to just
Suggested change
| find_package(PCL REQUIRED) | |
| if(PCL_VERSION VERSION_LESS "1.11.0") | |
| message(FATAL_ERROR "The found PCL version ${PCL_VERSION} is too low. Required is at least 1.11.0") | |
| endif() | |
| find_package(PCL 1.11.0 REQUIRED) |
Author
There was a problem hiding this comment.
So nice, @valgur, but if so, what if one uses PCL 1.12. or more higher version?
Plus, it's my personal question, but I'm curious whether it is possible to install multiple PCL versions on a machine. Thx!
Owner
There was a problem hiding this comment.
@LimHyungTae
Thanks for your contribution. The way suggested by @valgur only specifies the minimum required version and should accept newer versions.
Possibly you can switch different PCL versions with some cmake arguments. But, I'm not very familiar with the way handling multiple versions of a library in cmake.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Hi Koide, this is Hyungtae.
I added a version check line, so if a user turns on the PCL option (i.e., set
BUILD_WITH_PCLON), CMakeLists.txt automatically checks the PCL version and then rejects the build once the satisfaction of the PCL dependency does not meet as follows:Please check it.
Cheers!